#ifndef ENDCONNECTDESTHANDLERBASE_H
#define ENDCONNECTDESTHANDLERBASE_H

#include "ITransHandler.h"
#include "Log.h"

class EndConnectDestHandlerBase abstract:public ITransHandler
{
public:
	EndConnectDestHandlerBase():ITransHandler(){}

	~EndConnectDestHandlerBase(){}

	virtual ExecuteResultCode Execute(ClientContext&,OVERLAPPED*);

protected:
	virtual void GetSendInfo(ClientContext &client,SOCKET *sendSock,OVERLAPPED **sendOvl) abstract;

	virtual ITransHandler* GetNextHandler() abstract;

	virtual ExecuteResultCode OnExecuteError(ClientContext &client,OVERLAPPED *ovl,ITransHandler::ExecuteResultCode executeResult) abstract;

	virtual std::string* AssemblyHttpRequest(ClientContext&) abstract;

	virtual WSABUF* FillBufferWithHttpRequest(ClientContext &client,std::string *requestStr) abstract;

private:
	static log4cplus::Logger log;
};

#endif